#!/usr/bin/env python
# -*- coding: utf-8 -*-
# @Time    : 2018/9/17 14:18
# @Author  : youfeng


# 获得redis结果库
class RedisKeyWrap(object):
    '''
    redis store example:
    过期时长: 暂定1周
    result#gsxt#北京海致星图科技有限公司 : "{"total": 1, data_list: [{"﻿key_person": {}, "xxx": {}}]}"
    数据项item: 与app_data中数据格式保持一致。
    '''

    @staticmethod
    def get_gsxt_result_key(company):
        return "result#gsxt#{}".format(company)

    @staticmethod
    def get_wenshu_result_key(company):
        return "result#wenshu#{}".format(company)

    @staticmethod
    def get_news_result_key(company):
        return "result#news#{}".format(company)

    @staticmethod
    def get_zhixing_result_key(company):
        return "result#zhixing#{}".format(company)

    @staticmethod
    def get_shixin_result_key(company):
        return "result#shixin#{}".format(company)

    @staticmethod
    def get_gsxt_schedule_key(company):
        return "schedule#gsxt#{}".format(company)

    @staticmethod
    def get_wenshu_schedule_key(company):
        return "schedule#wenshu#{}".format(company)

    @staticmethod
    def get_news_schedule_key(company):
        return "schedule#news#{}".format(company)

    @staticmethod
    def get_zhixing_schedule_key(company):
        return "schedule#zhixing#{}".format(company)

    @staticmethod
    def get_shixin_schedule_key(company):
        return "schedule#shixin#{}".format(company)